/**
 * @author deming.su
 * @time 2022-02-16
 * @description vue脚手架的webpack配置
 */

module.exports = {
    lintOnSave: false,
    pages: {
        index: {
            template: './public/index.html',
            entry: './src/index.js'
        }
    },
    devServer: {
        open: true,
        port: 16666
    },
    // 实现数据请求代理配置
    proxy: {
        '/apis': {
            target: 'http://www.shuiyue.info:12600',
            // 需要将多余的/apis从地址中匹配掉
            pathRewrite: {
                // 重写地址规则
                '/apis': ''
            }
        },
        '/cart/list': {
            target: 'http://120.79.136.98/Hairdressing/project/getProinfos?page=1&limit=10',
            // 需要将多余的/apis从地址中匹配掉
            pathRewrite: {
                '/cart/list': ''
            }
        },

    }

}